﻿<%@ Control Language="VB" AutoEventWireup="false" CodeFile="GroupControl.ascx.vb" Inherits="WebForm_ManageVolunteer_GroupControl" %>

<script src="<%=Me.ResolveUrl("~/js/JScript.js") %>" type="text/javascript"></script>

<asp:Panel ID="panel1" runat="server" BackColor="white" BorderWidth="1" Style="cursor: move;"
    Width="400px">
        <br />
            <div align="center">
        <asp:Label ID="lblTitle" runat="server" Text="<%$ Resources:Title %>" SkinID="title"></asp:Label>
    </div>
    <br />
    <table>
        <tr>
            <td>
                <table>
                    <tr>
                        <td>
                            <asp:Label ID="lblGroupName" runat="server"  Text="<%$ Resources:GroupNameTitle%>"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="txtGroupName" runat="server"></asp:TextBox>
                        </td>
                        <td>
                            &nbsp;
                        </td>
                        <td>
                            <asp:Button ID="btnInsert" runat="server" Text="<%$ Resources:Insert%>" />
                        </td>
                    </tr>
                    <tr>
                        <td colspan="4">
                              <My:MyGridView ID="gv" runat="server" SkinID="pager" 
                              AllowPaging="True" AllowSorting="True" AllowHoverEffect="False" AllowHoverSelect="False"
                              EmptyDataText="<%$ Resources:NoData %>">
                                <Columns>
                                           <asp:TemplateField Visible="false">
                                                <Itemtemplate>
                                                    <asp:Label ID="lblgvGroupID" runat="server" Text='<%# Bind("GroupID") %>'></asp:Label>
                                                </Itemtemplate>
                                            </asp:TemplateField>
                                            <asp:BoundField DataField="VOrganizationName"  HeaderText="<%$ Resources:VOrganizationName %>" readonly="true" />
                                            <asp:TemplateField HeaderText="<%$ Resources:GroupName %>">
                                                <EditItemTemplate>
                                                    <asp:TextBox ID="txtgvGroupName" runat="server"  Text='<%# Bind("GroupName") %>'>></asp:TextBox>
                                                </EditItemTemplate>
                                                <Itemtemplate>
                                                    <asp:Label ID="lblgvGroupName" runat="server" Text='<%# Bind("GroupName") %>'></asp:Label>
                                                </Itemtemplate>
                                            </asp:TemplateField>
                                            <asp:TemplateField>
                                                <EditItemTemplate>
                                                    <asp:Button ID="btnUpdate" runat="server" CommandName="Update" 
                                                    Text="<%$ Resources:Update %>" />
                                                    <asp:Button ID="btnCancel" runat="server" CommandName="Cancel" 
                                                    Text="<%$ Resources:Cancel %>" />
                                               </EditItemTemplate>
                                               <ItemTemplate>
                                                   <asp:Button ID="btnEdit" runat="server" CommandName="Edit" 
                                                   Text="<%$ Resources:Edit %>" />
                                               </ItemTemplate>
                                           </asp:TemplateField>
                                           <asp:TemplateField >
                                               <ItemTemplate>
                                                    <asp:Button ID="btnDelete" runat="server" CommandName="Delete" 
                                                       Text="<%$ Resources:Delete %>"  Visible='<%# Bind("IsDelete") %>' />
                                                </ItemTemplate>
                                           </asp:TemplateField>
                                  </Columns>
                              </My:MyGridView>
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr>
            <td align="center">
                <asp:Button ID="btnOK" runat="server" Text="<%$ Resources:OK%>" />
                <asp:Button ID="btnExit" runat="server" Text="<%$ Resources:Exit%>" />
            </td>
        </tr>
    </table>
        <br />
</asp:Panel>
<asp:Button ID="btnDummy" runat="server" Style="display: none" SkinID="null" />
<ajaxToolkit:ModalPopupExtender ID="mpSearch" runat="server" TargetControlID="btnDummy"
    PopupControlID="panel1" CancelControlID="btnExit" PopupDragHandleControlID="panel1"  X="350" Y="350" />